home *** CD-ROM | disk | FTP | other *** search
/ PC World Komputer 2007 December / PCWKCD1207B.iso / Windows marzen / Macro ToolsWorks 6.31 / tworks.exe / Samples / Show registry subkeys.mcr < prev    next >
Text File  |  2003-09-05  |  683b  |  26 lines

  1. <#> 
  2. <#> Sample: Shows all subkeys of  HKEY_CURRENT_USER\Software
  3. <#> 
  4. <cmds>
  5.  
  6. <reg_enumsubkeys>("HKEY_CURRENT_USER\Software","vKey","vNumOfKeys")
  7.  
  8. <if_num>("vNumOfKeys==0")
  9.    <msg>(-100,-100,"No keys found under HKEY_CURRENT_USER\Software.","Message",1)
  10.    <exitmacro>
  11. <endif>
  12.  
  13. <#> Start Notepad and make it active window
  14. <execappex>("notepad.exe","","",0,0)
  15. <waitfor>("WIN","OPEN","mw[[  ]] mc[[ Notepad ]] cw[[  ]] cc[[  ]] ",5,0)
  16. <actwin>("mw[[  ]] mc[[ Notepad ]] cw[[  ]] cc[[  ]] ",0,0,"no")
  17.  
  18. <if_win>("mw[[  ]] mc[[ Notepad ]] cw[[  ]] cc[[  ]] ","ACT",0)
  19.  
  20. <begloop>(vNumOfKeys)
  21.    <varout>("vKey[_vLoopCounter0]",0)
  22.    <newline>
  23. <endloop>
  24.  
  25. <endif>
  26.